<?php



/**
 * Radcodes - SocialEngine Module
 *
 * @category   Application_Extensions
 * @package    Gmap
 * @copyright  Copyright (c) 2009-2010 Radcodes LLC (http://www.radcodes.com)
 * @license    http://www.radcodes.com/license/
 * @version    $Id$
 * @author     Vincent Van <vincent@radcodes.com>
 */
 
 
 
class Gmap_Widget_ListSearchController extends Engine_Content_Widget_Abstract
{

  public function indexAction()
  {
  	
    $viewer = Engine_Api::_()->user()->getViewer();

    $this->view->form = $form = new Gmap_Form_Search();

    if( !$viewer->getIdentity() )
    {
      $form->removeElement('show');
    }

    $form->setAction(Zend_Controller_Front::getInstance()->getRouter()->assemble(array(),'gmap_browse'));
    
    $this->view->can_create = Engine_Api::_()->authorization()->isAllowed('gmap', $viewer, 'create');
    
  }

}